<layout name="mun" />
    <div class="operation_user clearfix">
        <div class="link fl"><a href="#">商城</a><span>&gt;&gt;</span><a href="#">用户管理</a><span>&gt;&gt;</span>修改用户</div>
        <div class="link fr">
            <a href="#" class="icon icon_i">首页</a><span></span>欢迎您！<span>Admin</span><a href="#" class="icon icon_e">退出</a>
        </div>
    </div>
    <div class="content clearfix">
        <div class="main">
            <!--右侧内容-->
            <div class="cont">
                <div class="title">修改用户邮箱</div>
                <div class="details">
                	<div class="formDiv">
					  <div class="form-group">
					    <label for="userName" class="col-sm-2 control-label"></label>
					    <div class="col-sm-10">

                         <a>用户名</a><input disabled="true " type="text" class="form-control" name="username" id="username" value="{$rs[0]['username']}" placeholder="用户名"/>
                           <a>邮箱</a> <input type="text" class="form-control" name="email" id="email" value="{$rs[0]['email']}"placeholder="邮箱" />
                        </div>
					  </div>
					  <div class="form-group">
					    <div class="col-sm-offset-2 col-sm-10">
					      <button id="xiugai" value="{$rs[0]['id']}"  class="btn btn-primary">提交</button>
					    </div>
					  </div>
					</div>
                </div>
            </div>
        </div>
        <SCRIPT src="__JS__jquery-1.9.1.min.js" type="text/javascript"></SCRIPT>
        <script type="text/javascript">
        $(function(){
        	$('#xiugai').click(function(){
        		$.post("{:U('UserList/doXiugai')}",{
        			id:$(this).val(),
                    username:$("#username").val(),
                    email:$("#email").val()
        		},function(data){
        			if(data.status == 0){
        				alert(data.info);
        			}else{
        				alert(data.info);
        				location.href=data.url; 
        			}
        		});
        	});
        });
        </script>
